3.3.24 \(\int \sqrt {x} \sqrt {1-a x} \, dx\) [224]

Optimal. Leaf size=63 \[ -\frac {\sqrt {x} \sqrt {1-a x}}{4 a}+\frac {1}{2} x^{3/2} \sqrt {1-a x}+\frac {\sin ^{-1}\left (\sqrt {a} \sqrt {x}\right )}{4 a^{3/2}} \]

[Out]

1/4*arcsin(a^(1/2)*x^(1/2))/a^(3/2)+1/2*x^(3/2)*(-a*x+1)^(1/2)-1/4*x^(1/2)*(-a*x+1)^(1/2)/a

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 63, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.188, Rules used = {52, 56, 222} \begin {gather*} \frac {\text {ArcSin}\left (\sqrt {a} \sqrt {x}\right )}{4 a^{3/2}}+\frac {1}{2} x^{3/2} \sqrt {1-a x}-\frac {\sqrt {x} \sqrt {1-a x}}{4 a} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sqrt[x]*Sqrt[1 - a*x],x]

[Out]

-1/4*(Sqrt[x]*Sqrt[1 - a*x])/a + (x^(3/2)*Sqrt[1 - a*x])/2 + ArcSin[Sqrt[a]*Sqrt[x]]/(4*a^(3/2))

Rule 52

Int[((a_.) + (b_.)*(x_))^(m_)*((c_.) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(a + b*x)^(m + 1)*((c + d*x)^n/(b*(
m + n + 1))), x] + Dist[n*((b*c - a*d)/(b*(m + n + 1))), Int[(a + b*x)^m*(c + d*x)^(n - 1), x], x] /; FreeQ[{a
, b, c, d}, x] && NeQ[b*c - a*d, 0] && GtQ[n, 0] && NeQ[m + n + 1, 0] &&  !(IGtQ[m, 0] && ( !IntegerQ[n] || (G
tQ[m, 0] && LtQ[m - n, 0]))) &&  !ILtQ[m + n + 2, 0] && IntLinearQ[a, b, c, d, m, n, x]

Rule 56

Int[1/(Sqrt[(a_.) + (b_.)*(x_)]*Sqrt[(c_.) + (d_.)*(x_)]), x_Symbol] :> Dist[2/Sqrt[b], Subst[Int[1/Sqrt[b*c -
 a*d + d*x^2], x], x, Sqrt[a + b*x]], x] /; FreeQ[{a, b, c, d}, x] && GtQ[b*c - a*d, 0] && GtQ[b, 0]

Rule 222

Int[1/Sqrt[(a_) + (b_.)*(x_)^2], x_Symbol] :> Simp[ArcSin[Rt[-b, 2]*(x/Sqrt[a])]/Rt[-b, 2], x] /; FreeQ[{a, b}
, x] && GtQ[a, 0] && NegQ[b]

Rubi steps

\begin {align*} \int \sqrt {x} \sqrt {1-a x} \, dx &=\frac {1}{2} x^{3/2} \sqrt {1-a x}+\frac {1}{4} \int \frac {\sqrt {x}}{\sqrt {1-a x}} \, dx\\ &=-\frac {\sqrt {x} \sqrt {1-a x}}{4 a}+\frac {1}{2} x^{3/2} \sqrt {1-a x}+\frac {\int \frac {1}{\sqrt {x} \sqrt {1-a x}} \, dx}{8 a}\\ &=-\frac {\sqrt {x} \sqrt {1-a x}}{4 a}+\frac {1}{2} x^{3/2} \sqrt {1-a x}+\frac {\text {Subst}\left (\int \frac {1}{\sqrt {1-a x^2}} \, dx,x,\sqrt {x}\right )}{4 a}\\ &=-\frac {\sqrt {x} \sqrt {1-a x}}{4 a}+\frac {1}{2} x^{3/2} \sqrt {1-a x}+\frac {\sin ^{-1}\left (\sqrt {a} \sqrt {x}\right )}{4 a^{3/2}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 0.08, size = 64, normalized size = 1.02 \begin {gather*} \frac {1}{4} \left (\frac {\sqrt {x} \sqrt {1-a x} (-1+2 a x)}{a}+\frac {\log \left (-\sqrt {-a} \sqrt {x}+\sqrt {1-a x}\right )}{(-a)^{3/2}}\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[x]*Sqrt[1 - a*x],x]

[Out]

((Sqrt[x]*Sqrt[1 - a*x]*(-1 + 2*a*x))/a + Log[-(Sqrt[-a]*Sqrt[x]) + Sqrt[1 - a*x]]/(-a)^(3/2))/4

________________________________________________________________________________________

Maple [A]
time = 0.08, size = 84, normalized size = 1.33

method result size
meijerg \(\frac {\frac {\sqrt {\pi }\, \sqrt {x}\, \left (-a \right )^{\frac {3}{2}} \left (-6 a x +3\right ) \sqrt {-a x +1}}{6 a}-\frac {\sqrt {\pi }\, \left (-a \right )^{\frac {3}{2}} \arcsin \left (\sqrt {a}\, \sqrt {x}\right )}{2 a^{\frac {3}{2}}}}{2 \sqrt {-a}\, \sqrt {\pi }\, a}\) \(66\)
default \(-\frac {\sqrt {x}\, \left (-a x +1\right )^{\frac {3}{2}}}{2 a}+\frac {\sqrt {x}\, \sqrt {-a x +1}+\frac {\sqrt {\left (-a x +1\right ) x}\, \arctan \left (\frac {\sqrt {a}\, \left (x -\frac {1}{2 a}\right )}{\sqrt {-a \,x^{2}+x}}\right )}{2 \sqrt {-a x +1}\, \sqrt {x}\, \sqrt {a}}}{4 a}\) \(84\)
risch \(-\frac {\left (2 a x -1\right ) \sqrt {x}\, \left (a x -1\right ) \sqrt {\left (-a x +1\right ) x}}{4 a \sqrt {-x \left (a x -1\right )}\, \sqrt {-a x +1}}+\frac {\arctan \left (\frac {\sqrt {a}\, \left (x -\frac {1}{2 a}\right )}{\sqrt {-a \,x^{2}+x}}\right ) \sqrt {\left (-a x +1\right ) x}}{8 a^{\frac {3}{2}} \sqrt {x}\, \sqrt {-a x +1}}\) \(97\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^(1/2)*(-a*x+1)^(1/2),x,method=_RETURNVERBOSE)

[Out]

-1/2/a*x^(1/2)*(-a*x+1)^(3/2)+1/4/a*(x^(1/2)*(-a*x+1)^(1/2)+1/2*((-a*x+1)*x)^(1/2)/(-a*x+1)^(1/2)/x^(1/2)/a^(1
/2)*arctan(a^(1/2)*(x-1/2/a)/(-a*x^2+x)^(1/2)))

________________________________________________________________________________________

Maxima [A]
time = 0.54, size = 82, normalized size = 1.30 \begin {gather*} \frac {\frac {\sqrt {-a x + 1} a}{\sqrt {x}} - \frac {{\left (-a x + 1\right )}^{\frac {3}{2}}}{x^{\frac {3}{2}}}}{4 \, {\left (a^{3} - \frac {2 \, {\left (a x - 1\right )} a^{2}}{x} + \frac {{\left (a x - 1\right )}^{2} a}{x^{2}}\right )}} - \frac {\arctan \left (\frac {\sqrt {-a x + 1}}{\sqrt {a} \sqrt {x}}\right )}{4 \, a^{\frac {3}{2}}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^(1/2)*(-a*x+1)^(1/2),x, algorithm="maxima")

[Out]

1/4*(sqrt(-a*x + 1)*a/sqrt(x) - (-a*x + 1)^(3/2)/x^(3/2))/(a^3 - 2*(a*x - 1)*a^2/x + (a*x - 1)^2*a/x^2) - 1/4*
arctan(sqrt(-a*x + 1)/(sqrt(a)*sqrt(x)))/a^(3/2)

________________________________________________________________________________________

Fricas [A]
time = 1.97, size = 111, normalized size = 1.76 \begin {gather*} \left [\frac {2 \, {\left (2 \, a^{2} x - a\right )} \sqrt {-a x + 1} \sqrt {x} - \sqrt {-a} \log \left (-2 \, a x + 2 \, \sqrt {-a x + 1} \sqrt {-a} \sqrt {x} + 1\right )}{8 \, a^{2}}, \frac {{\left (2 \, a^{2} x - a\right )} \sqrt {-a x + 1} \sqrt {x} - \sqrt {a} \arctan \left (\frac {\sqrt {-a x + 1}}{\sqrt {a} \sqrt {x}}\right )}{4 \, a^{2}}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^(1/2)*(-a*x+1)^(1/2),x, algorithm="fricas")

[Out]

[1/8*(2*(2*a^2*x - a)*sqrt(-a*x + 1)*sqrt(x) - sqrt(-a)*log(-2*a*x + 2*sqrt(-a*x + 1)*sqrt(-a)*sqrt(x) + 1))/a
^2, 1/4*((2*a^2*x - a)*sqrt(-a*x + 1)*sqrt(x) - sqrt(a)*arctan(sqrt(-a*x + 1)/(sqrt(a)*sqrt(x))))/a^2]

________________________________________________________________________________________

Sympy [C] Result contains complex when optimal does not.
time = 1.77, size = 148, normalized size = 2.35 \begin {gather*} \begin {cases} \frac {i a x^{\frac {5}{2}}}{2 \sqrt {a x - 1}} - \frac {3 i x^{\frac {3}{2}}}{4 \sqrt {a x - 1}} + \frac {i \sqrt {x}}{4 a \sqrt {a x - 1}} - \frac {i \operatorname {acosh}{\left (\sqrt {a} \sqrt {x} \right )}}{4 a^{\frac {3}{2}}} & \text {for}\: \left |{a x}\right | > 1 \\- \frac {a x^{\frac {5}{2}}}{2 \sqrt {- a x + 1}} + \frac {3 x^{\frac {3}{2}}}{4 \sqrt {- a x + 1}} - \frac {\sqrt {x}}{4 a \sqrt {- a x + 1}} + \frac {\operatorname {asin}{\left (\sqrt {a} \sqrt {x} \right )}}{4 a^{\frac {3}{2}}} & \text {otherwise} \end {cases} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**(1/2)*(-a*x+1)**(1/2),x)

[Out]

Piecewise((I*a*x**(5/2)/(2*sqrt(a*x - 1)) - 3*I*x**(3/2)/(4*sqrt(a*x - 1)) + I*sqrt(x)/(4*a*sqrt(a*x - 1)) - I
*acosh(sqrt(a)*sqrt(x))/(4*a**(3/2)), Abs(a*x) > 1), (-a*x**(5/2)/(2*sqrt(-a*x + 1)) + 3*x**(3/2)/(4*sqrt(-a*x
 + 1)) - sqrt(x)/(4*a*sqrt(-a*x + 1)) + asin(sqrt(a)*sqrt(x))/(4*a**(3/2)), True))

________________________________________________________________________________________

Giac [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: NotImplementedError} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^(1/2)*(-a*x+1)^(1/2),x, algorithm="giac")

[Out]

Exception raised: NotImplementedError >> Unable to parse Giac output: Warning, choosing root of [1,0,%%%{4,[1,
1]%%%}+%%%{4,[1,0]%%%}+%%%{-4,[0,1]%%%}+%%%{-4,[0,0]%%%},0,%%%{6,[2,2]%%%}+%%%{4,[2,1]%%%}+%%%{6,[2,0]%%%}+%%%
{-4,[1,2]%%%}+%%%{-16

________________________________________________________________________________________

Mupad [B]
time = 2.60, size = 54, normalized size = 0.86 \begin {gather*} \sqrt {x}\,\left (\frac {x}{2}-\frac {1}{4\,a}\right )\,\sqrt {1-a\,x}-\frac {\ln \left (2\,\sqrt {-a}\,\sqrt {x}\,\sqrt {1-a\,x}-2\,a\,x+1\right )}{8\,{\left (-a\right )}^{3/2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^(1/2)*(1 - a*x)^(1/2),x)

[Out]

x^(1/2)*(x/2 - 1/(4*a))*(1 - a*x)^(1/2) - log(2*(-a)^(1/2)*x^(1/2)*(1 - a*x)^(1/2) - 2*a*x + 1)/(8*(-a)^(3/2))

________________________________________________________________________________________